List special directories when reading root directory on Android
authorPo Lu <luangruo@yahoo.com>
Sun, 31 Mar 2024 07:33:40 +0000 (15:33 +0800)
committerPo Lu <luangruo@yahoo.com>
Sun, 31 Mar 2024 07:41:04 +0000 (15:41 +0800)
commit7f377407b4b7d6ac9994ed983d7516bc42139885
treebc4987b10a05d3744b5632785a241f51f9493373
parentde8cae30bcf8283e4c3b069ccb8b75224659ac5c
List special directories when reading root directory on Android

* src/androidvfs.c (root_vfs_ops): Substitute
android_root_opendir for android_root_opendir.
(struct android_root_vdir): New structure.
(root_fd, root_fd_references): New variables.
(android_root_readdir, android_root_closedir, android_root_dirfd)
(android_root_opendir): New functions.
(android_fstatat_1): Test provided fd against root_fd, and if
they match, prefix FILENAME with the name of the root directory.

* lisp/ls-lisp.el (ls-lisp-insert-directory): If d-f-a-a signals
an error while retrieving attributes, compile the alist of
directory contents by hand.
lisp/ls-lisp.el
src/androidvfs.c